// https://www.cnblogs.com/573177885qq/p/5302457.html

#include <assert.h>
// #include <bitset>
#include <stdlib.h>

char *strcpy(char *des, const char *src){
       assert((des != nullptr) && (src != nullptr));//如果值为假，打印输出错误
       char *add = des;
       while ((*des++ = *src++ ) != '\0') ;
       return add;
}

typedef unsigned char byte;

void  *memcpy(void *pvTo, const void *pvFrom, size_t size) {
       assert((pvTo != nullptr) && (pvFrom != nullptr));      // 使用断言
       byte *pbTo = (byte *) pvTo;         // 防止改变pvTo的地址
       byte *pbFrom = (byte *) pvFrom; // 防止改变pvFrom的地址
       while(size -- > 0 )
              *pbTo = *pbFrom ;
       return pvTo;
}